{% extends "base.html" %}

{% block title %}注册签到{% endblock %}

{% block head %}
{{ super() }}
<link href="{{ static_url('register.css') }}" rel="stylesheet" type="text/css">
{% endblock %}

{% block body %}
<div class="container">
  <form method="POST">
    <h1>签到<sup>alpha</sup></h1>
    {% block reg %}<p class="alert alert-info">注册签到 (qiandao.today)</p>{% endblock %}
    <div class="form-group {{ 'has-error' if email_error }}">
      <label class="control-label" for="email">Email 地址</label>
      <input type="email" class="form-control" name="email" id="email" value="{{ email }}" placeholder="请输入 email 地址">
      {% if email_error %}<p class="text-danger">{{ email_error }}</p>{% endif %}
    </div>
    <div class="form-group {{ 'has-error' if password_error }}">
      <label for="password">密码</label>
      <input type="password" class="form-control" name="password" id="password" placeholder="请输入 密码">
      {% if password_error %}<p class="text-danger">{{ password_error }}</p>{% endif %}
    </div>
    <div class="text-right">
      <p><a href="/password_reset">忘记密码?</a></p>
      <button type="submit" class="btn btn-default" onclick="document.forms[0].action='/login'+location.search">登录</button>
      <button type="submit" class="btn btn-default" onclick="document.forms[0].action='/register'+location.search">注册</button>
    </div>
</div>
{{ utils.submit_loading() }}
{% endblock %}
